﻿using System;
using System.Data;
using System.Runtime.Serialization;
using System.ServiceModel;

namespace HRMService
{
    // NOTE: If you change the interface name "ILaterInsurance" here, you must also update the reference to "ILaterInsurance" in App.config.
    [ServiceContract(Namespace = "http://HRMService")]
    public interface ILaterInsurance
    {
        [OperationContract]
        DataSet LaterInsurance_GetForTrichNop(int month, int year);

        [OperationContract]
        DataSet LaterInsurance_GetALL();

        [OperationContract]
        bool LaterInsurance_CheckEmployee(int EmployeeID, int month, int year);

        [OperationContract]
        LaterInsuranceInfo LaterInsurance_GetMonthWithEmployee(int EmployeeID, int month, int year);

        [OperationContract]
        DataSet LaterInsurance_TruyDong(int month, int year);

        [OperationContract]
        LaterInsuranceInfo LaterInsurance_GetInfo(int LaterInsuranceID);

        [OperationContract]
        DataSet LaterInsurance_GetList(out int itemCount, int currPage, int pageSize,int BranchID, int DepartmentID, int month, int year);
        
        [OperationContract]
        bool LaterInsurance_CheckExistEmployee(int EmployeeID, int month, int year);

        [OperationContract]
        int LaterInsurance_Insert(LaterInsuranceInfo eInfo);

        [OperationContract]
        bool LaterInsurance_Update(LaterInsuranceInfo eInfo);
    }
    [DataContract(Namespace = "http://HRMService")]
    public class LaterInsuranceInfo
    {
        int _ID;
        [DataMember]
        public int ID
        {
            get { return _ID; }
            set { _ID = value; }
        }

        int _EmployeeID;
        [DataMember]
        public int EmployeeID
        {
            get { return _EmployeeID; }
            set { _EmployeeID = value; }
        }

        int _DepartmentID;
        [DataMember]
        public int DepartmentID
        {
            get { return _DepartmentID; }
            set { _DepartmentID = value; }
        }

        int _PositionID;
        [DataMember]
        public int PositionID
        {
            get { return _PositionID; }
            set { _PositionID = value; }
        }

        decimal _OverTime;
        [DataMember]
        public decimal OverTime
        {
            get { return _OverTime; }
            set { _OverTime = value; }
        }

        DateTime _date;
        [DataMember]
        public DateTime Date
        {
            get { return _date; }
            set { _date = value; }
        }

        decimal _CompanyLunch;
        [DataMember]
        public decimal CompanyLunch
        {
            get { return _CompanyLunch; }
            set { _CompanyLunch = value; }
        }

        decimal _BasicFactor;
        [DataMember]
        public decimal BasicFactor
        {
            get { return _BasicFactor; }
            set { _BasicFactor = value; }
        }

        decimal _PositionFactor;
        [DataMember]
        public decimal PositionFactor
        {
            get { return _PositionFactor; }
            set { _PositionFactor = value; }
        }

        decimal _SeniorityFactor;
        [DataMember]
        public decimal SeniorityFactor
        {
            get { return _SeniorityFactor; }
            set { _SeniorityFactor = value; }
        }

        decimal _OverSeniorityFactor;
        [DataMember]
        public decimal OverSeniorityFactor
        {
            get { return _OverSeniorityFactor; }
            set { _OverSeniorityFactor = value; }
        }

        decimal _BasicSalary;
        [DataMember]
        public decimal BasicSalary
        {
            get { return _BasicSalary; }
            set { _BasicSalary = value; }
        }

        decimal _PositionAllowance;
        [DataMember]
        public decimal PositionAllowance
        {
            get { return _PositionAllowance; }
            set { _PositionAllowance = value; }
        }

        decimal _SeniorityAllowance;
        [DataMember]
        public decimal SeniorityAllowance
        {
            get { return _SeniorityAllowance; }
            set { _SeniorityAllowance = value; }
        }

        decimal _OverSeniorityAllowance;
        [DataMember]
        public decimal OverSeniorityAllowance
        {
            get { return _OverSeniorityAllowance; }
            set { _OverSeniorityAllowance = value; }
        }

        decimal _CompanyFactor;
        [DataMember]
        public decimal CompanyFactor
        {
            get { return _CompanyFactor; }
            set { _CompanyFactor = value; }
        }

        decimal _CompanySalary;
        [DataMember]
        public decimal CompanySalary
        {
            get { return _CompanySalary; }
            set { _CompanySalary = value; }
        }

        decimal _ResponseFactor;
        [DataMember]
        public decimal ResponseFactor
        {
            get { return _ResponseFactor; }
            set { _ResponseFactor = value; }
        }

        decimal _ResponseSalary;
        [DataMember]
        public decimal ResponseSalary
        {
            get { return _ResponseSalary; }
            set { _ResponseSalary = value; }
        }

        int _TotalDateWork;
        [DataMember]
        public int TotalDateWork
        {
            get { return _TotalDateWork; }
            set { _TotalDateWork = value; }
        }

        int _TotalDateOutWork;
        [DataMember]
        public int TotalDateOutWork
        {
            get { return _TotalDateOutWork; }
            set { _TotalDateOutWork = value; }
        }

        int _TotalLeaveUnPaid;
        [DataMember]
        public int TotalLeaveUnPaid
        {
            get { return _TotalLeaveUnPaid; }
            set { _TotalLeaveUnPaid = value; }
        }

        int _TotalLeavePaid;
        [DataMember]
        public int TotalLeavePaid
        {
            get { return _TotalLeavePaid; }
            set { _TotalLeavePaid = value; }
        }

        decimal _OtherResponse;
        [DataMember]
        public decimal OtherResponse
        {
            get { return _OtherResponse; }
            set { _OtherResponse = value; }
        }

        decimal _OtherDeduction;
        [DataMember]
        public decimal OtherDeduction
        {
            get { return _OtherDeduction; }
            set { _OtherDeduction = value; }
        }

        decimal _TelephoneCost;
        [DataMember]
        public decimal TelephoneCost
        {
            get { return _TelephoneCost; }
            set { _TelephoneCost = value; }
        }

        decimal _IncomeTax;
        [DataMember]
        public decimal IncomeTax
        {
            get { return _IncomeTax; }
            set { _IncomeTax = value; }
        }

        decimal _TradeUnion;
        [DataMember]
        public decimal TradeUnion
        {
            get { return _TradeUnion; }
            set { _TradeUnion = value; }
        }

        decimal _ProbationFactor;
        [DataMember]
        public decimal ProbationFactor
        {
            get { return _ProbationFactor; }
            set { _ProbationFactor = value; }
        }

        decimal _EmployeeSocialInc;
        [DataMember]
        public decimal EmployeeSocialInc
        {
            get { return _EmployeeSocialInc; }
            set { _EmployeeSocialInc = value; }
        }

        decimal _EmployeeMedicalInc;
        [DataMember]
        public decimal EmployeeMedicalInc
        {
            get { return _EmployeeMedicalInc; }
            set { _EmployeeMedicalInc = value; }
        }

        decimal _SocialInc;
        [DataMember]
        public decimal SocialInc
        {
            get { return _SocialInc; }
            set { _SocialInc = value; }
        }

        decimal _MedicalInc;
        [DataMember]
        public decimal MedicalInc
        {
            get { return _MedicalInc; }
            set { _MedicalInc = value; }
        }

        DateTime _MonthChange;
        [DataMember]
        public DateTime MonthChange
        {
            get { return _MonthChange; }
            set { _MonthChange = value; }
        }
    }
}
